import { TypeBase } from './types';

export default {
  value: {
    type: Array as PropType<Recordable[]>,
    default: () => [],
  },
  // 是否全路径
  fullPath: {
    type: Boolean,
    default: false,
  },
  // 是否可点击
  disabled: {
    type: Boolean,
    default: false,
  },
  // label key
  labelField: {
    // required: true,
    type: String,
    default: 'name',
  },
  record: {
    type: Object,
    default: () => {},
  },
  // value key
  valueField: {
    // required: true,
    type: String,
    default: 'id',
  },
  // 是否为综合组件
  synthesis: {
    type: Boolean,
    default: true,
  },
  apiCode: {
    type: Array,
    default: () => [],
  },
  // 类型
  type: {
    // required: true,
    type: String as PropType<TypeBase>,
    default: 'user',
  },
  // 左侧tree api
  leftApiUrl: {
    type: String,
    default: '',
  },
  // 中间tree api
  centerApiUrl: {
    type: String,
    default: '',
  },
  // 最大可选数量
  maxSelect: {
    type: Number,
    default: Infinity,
  },
  //最小可选数量
  minSelect: {
    type: Number,
    default: 0,
  },
  // 弹窗标题
  title: {
    type: String,
    default: '',
  },
  width: {
    type: String,
    default: '',
  },
};
